1. /* sromuldb.cpp by K.Tsuru */
  2. // function ID = 824 BRADIX
  3. /************************
  4. SRational class
  5. operator *=double
  6. *************************/
  7. #ifndef SN_H
  8. #include "sn.h"
  9. #endif
  10. SRational operator*(const SRational& m, double d){
  11. SRational r; // r.reduceDone = 0;
  12. if(d == 0.0) r.SetZero();
  13. else if(d == 1.0L) r = m;
  14. else if(d == -1.0L) r = -m;
  15. else r.Set( m.NumNR()*(SInteger)d, m.DenNR() ); // includes r.reduce(false);
  16. return r;
  17. }

sromuldb.cpp : last modifiled at 2016/06/26 16:29:28(463 bytes)
created at 2016/06/26 15:57:35
The creation time of this html file is 2016/09/18 20:28:05 (Sun Sep 18 20:28:05 2016).